package com.fll.fangyicommon.entity.share;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fll.fangyicommon.entity.user.User;
import lombok.Data;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;

import java.util.ArrayList;

/**
 * @author fll
 * create 2023/3/20
 */
@Setter
@Getter
@NoArgsConstructor
@Data
public class Share {

    @TableId
    private Integer shareId;

    @TableField(exist = false)
    //外键-用户id
    private Integer userId;
    //分享内容，说说内容
    private String shareContent;
    //分享被转发数
    private String transCount;
    //说说发布时间
    private String createTime;
    //预留,暂未使用
    private String yl;

    @TableField(exist = false)
    private ArrayList<String> oss; //只赋值url图片

    @TableField(exist = false)
    private Boolean isLike; //登录用户是否点赞

    @TableField(exist = false)
    private int likedCount; //点赞总数

    @TableField(exist = false)
    private Boolean isComment; //登录用户是否评论

    @TableField(exist = false)
    private int commentCount; //评论总数

    @TableField(exist = false)
    ArrayList<Comment> commentList; //获取share所有的评论

    @TableField(exist = false)
    private Boolean isCollect; //登录用户是否收藏

    @TableField(exist = false)
    private int collectCount; //收藏总数

    @TableField(exist = false)
    private User user; //share的所属user
}
